Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move Current Components to Experimental Section in Storybook #273

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from

Conversation

sreidthomas
Copy link
Contributor

@sreidthomas sreidthomas commented Dec 21, 2024

Move Current Components to Experimental Section in Storybook

This PR introduces an Experimental section in Storybook and moves all current components and form components under this section. Additionally, it updates build configurations and scripts to reflect these changes.


Key Updates

1. Create Experimental Section in Storybook
  • Updated the title property in each story file for the components and form components to include Experimental/ as a prefix.
    • For example:
      • Changed "Components/Button" to "Experimental/Components/Button".
      • Changed "Forms/Input" to "Experimental/Forms/Input".
  • Outcome: Components now appear under the "Experimental" section in the Storybook sidebar.
2. Update Documentation
  • Updated the documentation under the COD UXDS section to include the following details:

    Experimental Components
    These components are unstable and should only be used for testing purposes. They:

    • May undergo significant changes.
    • Are not suitable for production environments.
    • Should be used at the user's own risk.
3. Rename Component Index
  • Renamed the main component index file:
    • From: src/index.js
    • To: src/index-experimental.js.
  • Updated the Webpack configuration:
    • Changed the entry point:
      • From: ./src/index.js
      • To: ./src/index-experimental.js.
    • Updated the build output directory:
      • From: build/
      • To: build/experimental/.
  • Verified functionality by running npm run build and yarn storybook.
4. Rename Build Script
  • Updated the package.json file:
    • Renamed the build script:
      • From: "build": "webpack --mode production"
      • To: "build:experimental": "webpack --mode production".
  • Verified the build process by running yarn build:experimental.

Testing

  1. Ran yarn storybook to ensure the updated structure appears correctly in the Storybook sidebar.
  2. Built the experimental components package with yarn build:experimental to confirm the build output in the correct directory.

Notes

  • Folder Structure: No changes were made to the folder structure of components. The section titles in Storybook were updated by modifying the title field in the respective story files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant